﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

public partial class Employees_EmpIssue : System.Web.UI.Page
{
    private Srvtools.WebDataSet WMaster;

    protected void Page_Load(object sender, EventArgs e)
    {
        if (!IsPostBack)
        {
            InitializeComponent();

            WMaster.SetWhere("Train_Practice.EmployeeID=" + Request["eid"].ToString());

            Master.DataSource = WMaster;
            ((HiddenField)this.Page.Master.FindControl("HoverId")).Value = "EmpIssue";
      


            MasterPage_MasterPage_EmpDetail master = (MasterPage_MasterPage_EmpDetail)this.Page.Master;
            master.HelpHref = "";
            master.PageName = "员工培训";
            master.PicUrl = "~/image/PageIcon/zhiwei.jpg";
            master.IntiBar();
        }
    }

    private void InitializeComponent()
    {
        System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(Employees_EmpIssue));
        this.WMaster = new Srvtools.WebDataSet();
        ((System.ComponentModel.ISupportInitialize)(this.WMaster)).BeginInit();
        // 
        // WMaster
        // 
        this.WMaster.Active = true;
        this.WMaster.AlwaysClose = false;
        this.WMaster.PacketRecords = 100;
        this.WMaster.Position = -1;
        this.WMaster.RemoteName = "Train.View_IssueList";
        this.WMaster.ServerModify = false;
        ((System.ComponentModel.ISupportInitialize)(this.WMaster)).EndInit();

    }

    protected void wgvMaster_DataBound(object sender, EventArgs e)
    {
        if (Request["action"] != null)
        {
            if (Request["action"].ToString() == "edit")
            {
                TabsFunction.Visible = true;
                AddFunction.Attributes.Add("onclick", "ymPrompt.win({title:'培 训 添 加',message:'../Train/IssuePractice.aspx?ItemParam=',closeBtn:true,iframe:true,allowRightMenu:false,allowSelect:false});ymPrompt.max();return false");
            }
            else
            {
                TabsFunction.Visible = false;
            }
        }
        else
        {
            TabsFunction.Visible = false;
        }
    }
}
